import request from '@/utils/request';

// 获取员工列表
export function getEmployeeList() {
  return request({
    url: '/api/api/employees/getList',
    method: 'get',
  });
}
// 添加员工
export function searchEmployee(data) {
  return request({
    url: '/api/api/employees/searchEmployee',
    method: 'post',
    data,
  });
}

// 添加员工
export function addEmployee(data) {
  return request({
    url: '/api/api/employees/addEmployee',
    method: 'post',
    data,
  });
}

// 更新员工
export function updateEmployee(id, data) {
  return request({
    url: `/api/api/employees/updateEmployee/${id}`,
    method: 'put',
    data,
  });
}

// 删除员工
export function deleteEmployee(id) {
  return request({
    url: `/api/api/employees/deleteEmployee/${id}`,
    method: 'delete',
  });
} 